package com.bruce.demo2.patterns.demo2.structural.demo06.proxy.demo2;

/**
 * @PROJECT_NAME design_patterns
 * @DESCRIPTION 测试类
 * @AUTHOR CNBruceLee
 * @DATE 2021/7/15 6:57
 */
public class Test {

    public static void main(String[] args) {
        ProxyFactory factory = new ProxyFactory();
        SellTickets sellTickets = factory.getProxyObject();
        sellTickets.sell();

        System.out.println(sellTickets.getClass());//-->class com.sun.proxy.$Proxy0
        //通过arthas 获取内存中动态生产的代理类 -->$Proxy0 已在代码中映射了，可以查看具体创建的类
        while (true) {
        }
    }
}
